package cn.edu.sjtu.stap.cg;

import org.aspectj.org.eclipse.jdt.internal.compiler.ast.ASTNode;

import cn.edu.sjtu.stap.graph.*;

public abstract class CgEdge extends GraphEdge {
    private static final long serialVersionUID = 1L;

    private static long edgeCount = 0;

    protected ASTNode astNode;

    protected CgEdge() {
        super(++edgeCount);
    }

    protected CgEdge(CgNode from, CgNode to) {
        super(++edgeCount, from, to);
    }

    public void setASTNode(ASTNode node) {
        this.astNode = node;
    }
    
    public ASTNode getASTNode() {
        return astNode;
    }
    
    public abstract String toString();
}
